#include <stdio.h>

int mySqrt(int x)
{
    for(int i = 1;i <= x/2;i++)
    {
        if(i * i > x)
        {
            return i - 1;
        }
    }
}

int main()
{
    unsigned int  x = 9;
    printf("%d\n",mySqrt(x));
    return 0;
}